package com.ruoyi.novel.service.impl;

import com.ruoyi.common.core.web.domain.AjaxResult;
import com.ruoyi.novel.domain.Directory;
import com.ruoyi.novel.domain.NovelDTO;
import com.ruoyi.novel.domain.Read;
import com.ruoyi.novel.mapper.ReadMapper;
import com.ruoyi.novel.service.ReadService;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class ReadServiceImpl implements ReadService {
    @Autowired
    private ReadMapper readMapper;

    @Override
    public Read getNovelContent(String title) {
        Read read = readMapper.getNovelContent(title);
        return read;
    }

    @Override
    public List<Directory> getNovelChapter(String title) {
        List<Directory> directory = readMapper.getNovelChapter(title);
        return directory;
    }

    @Override
    public int sign(Long userId) {
      return readMapper.sign(userId);
    }
}
